package cn.yunhe.biz.impl;

import cn.yunhe.biz.RecordBiz;
import cn.yunhe.dao.RecordDao;
import cn.yunhe.pojo.Record;

import java.util.List;

public class RecordBizImpl implements RecordBiz {
    RecordDao recordDao;
    @Override
    public boolean insertRecord(Record record) {
        return recordDao.insertRecord(record);
    }

    @Override
    public boolean updateRecord(Record record) {
        return recordDao.updateRecord(record);
    }

    @Override
    public boolean deleteRecord(int id) {
        return recordDao.deleteRecord(id);
    }

    @Override
    public Record getById(int id) {
        return recordDao.getById(id);
    }

    @Override
    public List<Record> findRecord(String hql) {
        return recordDao.findRecord(hql);
    }

    @Override
    public List<Record> findRecord(Record record) {
        return recordDao.findRecord(record);
    }

    public RecordDao getRecordDao() {
        return recordDao;
    }

    public void setRecordDao(RecordDao recordDao) {
        this.recordDao = recordDao;
    }
}
